package com.dnjn.happiness.biz.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableLogic;
import com.baomidou.mybatisplus.annotation.TableName;
import com.dnjn.happiness.common.core.web.domain.BaseEntity;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.ToStringSerializer;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.NotNull;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 * 圈子
 * </p>
 *
 * @author Amber
 * @since 2023-10-04
 */
@Getter
@Setter
@TableName("biz_moments")
public class Moments extends BaseEntity {

    private static final long serialVersionUID = 1L;

    /**
     * PK
     */
    @JsonSerialize(using = ToStringSerializer.class)
    @TableId(value = "moments_id", type = IdType.ASSIGN_ID)
    private Long momentsId;

    
    



    private Long deptId;
    /**
     * sys_user.user_id
     */
    private Long userId;

    private LocalDateTime dateCurrent;
    /**
     * 情绪类型ID
     */
    @NotNull(message = "etypeId不能为空")
//    @Schema(requiredMode = Schema.RequiredMode.REQUIRED)
    private Long etypeId;

    @NotNull(message = "siteId不能为空")
//    @Schema(requiredMode = Schema.RequiredMode.REQUIRED)
    private Long siteId;


    @NotBlank(message = "wbtext不能为空")
//    @Schema(requiredMode = Schema.RequiredMode.REQUIRED)
    private String wbtext;

    private String momentsStatus;

    private Integer commentsCount;

    /**
     * 是否删除|0-否 1-是|valid
     */
    @TableLogic
    private String deleted;

    //    @Schema(requiredMode = Schema.RequiredMode.REQUIRED)
    @TableField(exist = false)
    private List<String> images;

    @TableField(exist = false)
    private String username;

    @TableField(exist = false)
    private String avatar;
    @TableField(exist = false)
    private String emotionType;
    @TableField(exist = false)
    private String emotionScore;


}
